Matthias Clasen [Tue, 18 May 2021 10:31:57 +0000 (10:31 +0000)]
Merge branch 'fix-gen-demo-conf' into 'master'
Fix generating demo_conf.h on builds without GIT in PATH
See merge request GNOME/gtk!3562
Chun-wei Fan [Tue, 18 May 2021 03:02:27 +0000 (11:02 +0800)]
gen-demo-header.py: Fix running without git
The script assumes that the git program is in the PATH which may not be always
the case, so if git was not found, fallback to the former behavior of making
VCS_TAG an empty string if the profile option was not set to 'devel'.
Also fix the call to the script so that we do indeed call GIT on the source GIT
repo so that we can get the right short SHA1 sum.
Re-organize the code a bit in the process, so that things seem cleaner.
Matthias Clasen [Mon, 17 May 2021 23:35:26 +0000 (23:35 +0000)]
Merge branch 'wip/carlosg/reset-after-grab' into 'master'
Fixes to GTK grab notification
Closes #3942
See merge request GNOME/gtk!3561
Carlos Garnacho [Mon, 17 May 2021 21:57:17 +0000 (23:57 +0200)]
gtkwindow: Fix "shadowed" checks for GTK grabs
We iterate here from the target widget up the toplevel checking
for the previous and new grab, there's however 2 bugs here:
- The check for is_shadowed was different to the check for was_shadowed
- The loop started with the assumption that the widgets did not hold
a grab, just to change it if the grab widget was found. (or maybe
it's the other way around? it's unclear with the differing checks
for past/present state).
Make these checks consistent, and ensure we start with the right
assumption for the past/present grabbing state, and accounting that
new/old grab widgets may or may not be part of the pick stack.
Carlos Garnacho [Mon, 17 May 2021 21:55:47 +0000 (23:55 +0200)]
gtkwindow: Rename function
With gtk_grab_notify_foreach() just taking care of emitting crossing
notifications due to the GTK grab change, rename it to a more apt
gtk_synthesize_grab_crossing().
Carlos Garnacho [Mon, 17 May 2021 21:44:28 +0000 (23:44 +0200)]
gtkwindow: Simplify GTK grab notification
The _gtk_widget_grab_notify() function just (maybe) did a) reset
controllers and b) hide toplevels. The second part was a testing
remnant introduced in commit
024d832d943, not part of the original
fix.
Do the former more concisely, called from the place where we figure
out whether a widget's ability to receive events changed due to
GTK grabs. It's across those changes that we are interested in
resetting the controllers.
With the gestures being reset both ways, GtkWindowHandle (and
probably other) gestures are now able to reset after a GTK grab
takes input away (e.g. GtkMenuButton). This could be seen as
a sudden jump the next time they'd be dragged with the mouse,
as the gesture would "resume" the previous interaction.
Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3942
Matthias Clasen [Mon, 17 May 2021 21:13:04 +0000 (21:13 +0000)]
Merge branch 'ebassi/rev-parse-fallback' into 'master'
build: Check CI envvars before rev-parse
See merge request GNOME/gtk!3559
Emmanuele Bassi [Mon, 17 May 2021 20:12:09 +0000 (21:12 +0100)]
build: Check CI envvars before rev-parse
The CI pipeline does not do a full clone, so we cannot use `git
rev-parse` to get the short SHA checksum for the current commit.
Of course, since nothing's ever easy, we cannot use vcs_tag() with a
custom command, so we need to generate our out `demo_conf.h` header
straight from a script.
Matthias Clasen [Mon, 17 May 2021 20:10:12 +0000 (20:10 +0000)]
Merge branch 'wip/exalm/activatable2' into 'master'
theme: Specificity bump for dropdowns
See merge request GNOME/gtk!3558
Alexander Mikhaylenko [Mon, 17 May 2021 18:25:44 +0000 (23:25 +0500)]
theme: Specificity bump for dropdowns
Fix a fallout from
d56711b5d82f8a77793a0857c2252565fda1b492
Matthias Clasen [Mon, 17 May 2021 15:56:02 +0000 (15:56 +0000)]
Merge branch 'wip/exalm/activatable' into 'master'
listitemwidget: Have .activatable style class if the item is activatable
See merge request GNOME/gtk!3557
Alexander Mikhaylenko [Mon, 17 May 2021 13:05:05 +0000 (18:05 +0500)]
listitemwidget: Have .activatable style class if the item is activatable
Match GtkListBox, so it's possible to use the same styles for them.
Update GtkListView and GtkGridView docs to reflect that, fix a few gtk-doc
formatting leftovers along the way.
Matthias Clasen [Mon, 17 May 2021 12:12:22 +0000 (12:12 +0000)]
Merge branch 'matthiasc/for-master' into 'master'
ngl: Add padding between cached glyphs
See merge request GNOME/gtk!3555
Matthias Clasen [Mon, 17 May 2021 11:16:42 +0000 (07:16 -0400)]
testsuite: Run some installed tests exclusively
My suspicion is that the clipboard (and some other)
installed test interferes with others, because the
clipboard is a shared resource.
Matthias Clasen [Mon, 17 May 2021 11:10:33 +0000 (11:10 +0000)]
Merge branch 'wip/exalm/emojichooser' into 'master'
emojichooser: Set selection-mode=none on the toolbar flowbox
See merge request GNOME/gtk!3556
Alexander Mikhaylenko [Mon, 17 May 2021 09:09:03 +0000 (14:09 +0500)]
emojichooser: Set selection-mode=none on the toolbar flowbox
Selection is never used there, avoid unwanted selected states if clicking
outside the buttons.
Pawan Chitrakar [Sun, 16 May 2021 07:41:02 +0000 (07:41 +0000)]
Update Nepali translation
(cherry picked from commit
597a624fc55975513517aa5514e5f4b3d838745e)
Matthias Clasen [Sat, 15 May 2021 13:00:50 +0000 (09:00 -0400)]
ngl: Reuse texture coordinates
When uploading glyphs, reuse the position that
we get from gsk_ngl_texture_library_pack, instead
of recomputing it.
Matthias Clasen [Sat, 15 May 2021 12:58:50 +0000 (08:58 -0400)]
ngl: Be consistent about padding
Make gsk_ngl_texture_library_pack always return
the position including the padding. And compute
texture coordinates accurately in all cases (we
were fudging the padding for standalone textures.
Matthias Clasen [Fri, 14 May 2021 22:43:52 +0000 (18:43 -0400)]
ngl: Add padding between cached glyphs
Without this, adjacent items in the cache sometimes
bleed into the texture for a glyph.
Matthias Clasen [Sat, 15 May 2021 14:21:09 +0000 (14:21 +0000)]
Merge branch 'gst-egl-optional' into 'master'
meson: Do not enforce GStreamer EGL lib
See merge request GNOME/gtk!3554
Rafał Dzięgiel [Sat, 15 May 2021 06:52:36 +0000 (08:52 +0200)]
meson: Do not enforce GStreamer EGL lib
GStreamer EGL headers are handled by GstGL lib.
No need to additionally import them.
Kjartan Maraas [Sat, 15 May 2021 07:35:03 +0000 (07:35 +0000)]
Update Norwegian Bokmål translation
(cherry picked from commit
d952fa48e783cfdd82c7a1a3191f1eb59ed6ad27)
Matthias Clasen [Fri, 14 May 2021 19:57:05 +0000 (19:57 +0000)]
Merge branch 'gst-x11-egl' into 'master'
gtkgstsink: Support EGL under x11
See merge request GNOME/gtk!3553
Rafał Dzięgiel [Fri, 14 May 2021 17:25:23 +0000 (19:25 +0200)]
gtkgstsink: Support EGL under x11
Add support for EGL under x11 windowing system to GStreamer sink
Matthias Clasen [Fri, 14 May 2021 10:50:59 +0000 (10:50 +0000)]
Merge branch 'ebassi/issue-3948' into 'master'
x11: Loosen the match for the NVIDIA driver
Closes #3948
See merge request GNOME/gtk!3549
Matthias Clasen [Fri, 14 May 2021 00:40:05 +0000 (00:40 +0000)]
Merge branch 'matthiasc/for-master' into 'master'
inspector: Use new get_egl_display apis
See merge request GNOME/gtk!3546
Matthias Clasen [Fri, 14 May 2021 00:38:52 +0000 (00:38 +0000)]
Merge branch 'offscreen-fixes' into 'master'
Add some more transform tests
See merge request GNOME/gtk!3551
Matthias Clasen [Thu, 13 May 2021 21:32:52 +0000 (17:32 -0400)]
Improve transformed offscreen rendering
Preserve the scale for 2D transforms to
avoid a pixellated appearance.
Matthias Clasen [Thu, 13 May 2021 10:47:46 +0000 (06:47 -0400)]
Add some more transform tests
Test that gsk_transform_to_affine works.
Matthias Clasen [Thu, 13 May 2021 22:58:34 +0000 (18:58 -0400)]
testzoom: Fix the in-place rotate
Matthias Clasen [Wed, 12 May 2021 19:57:33 +0000 (15:57 -0400)]
inspector: Use new get_egl_display apis
This makes the code a bit more concise.
Also, get WGL information when we are using it.
Emmanuele Bassi [Thu, 13 May 2021 17:23:50 +0000 (18:23 +0100)]
x11: Pair eglInitialize with eglTerminate
If we bail out after EGL initialization we want to go back to a stable
state and not leave EGL hanging.
Emmanuele Bassi [Thu, 13 May 2021 17:22:30 +0000 (18:22 +0100)]
x11: Loosen the match for the NVIDIA driver
It seems nVidia puts a different string in the GL_VENDOR than the one it
uses for GLX.
Emmanuele Bassi [Thu, 13 May 2021 11:47:28 +0000 (11:47 +0000)]
Merge branch 'ebassi/boost-url' into 'master'
Update the URL for the Boost archive
See merge request GNOME/gtk!3548
Emmanuele Bassi [Thu, 13 May 2021 10:29:22 +0000 (11:29 +0100)]
Update the URL for the Boost archive
The old URL seems to have failed, and now it returns 301.
Use the URL from the Boost website.
Matthias Clasen [Thu, 13 May 2021 10:09:37 +0000 (10:09 +0000)]
Merge branch 'fix-picking-with-transforms' into 'master'
Fix picking with transforms
See merge request GNOME/gtk!3547
Matthias Clasen [Thu, 13 May 2021 01:50:32 +0000 (21:50 -0400)]
Add a transform test
This reveals some issues with scale handling.
Matthias Clasen [Thu, 13 May 2021 00:53:41 +0000 (20:53 -0400)]
Fix picking with transforms
When transforms include scales, we weren't picking
children properly. The special-case in gtk_widget_do_pick
only applies to 2D translations.
Emmanuele Bassi [Wed, 12 May 2021 20:12:13 +0000 (20:12 +0000)]
Merge branch 'ebassi/issue-3945' into 'master'
docs: Fix indentation of the arguments
Closes #3945
See merge request GNOME/gtk!3544
Matthias Clasen [Wed, 12 May 2021 18:43:33 +0000 (18:43 +0000)]
Merge branch 'wip/chergert/fix-gi-typo' into 'master'
gdk: fix typo in G-I attribute
See merge request GNOME/gtk!3545
Matthias Clasen [Wed, 12 May 2021 18:42:35 +0000 (18:42 +0000)]
Merge branch 'win32.egl.getter' into 'master'
Win32: Add EGLDisplay getter
See merge request GNOME/gtk!3543
Christian Hergert [Wed, 12 May 2021 17:53:56 +0000 (10:53 -0700)]
gdk: fix typo in G-I attribute
Emmanuele Bassi [Wed, 12 May 2021 16:38:07 +0000 (17:38 +0100)]
docs: Fix indentation of the arguments
The indentation of new lines inside documentation blurbs must be smaller
than 4 spaces, otherwise the Markdown parser will consider the line to
be part of a pre-formatted code block.
Fixes: #3945
Chun-wei Fan [Wed, 12 May 2021 11:29:05 +0000 (19:29 +0800)]
Win32: Add EGLDisplay getter
Like what was done for Wayland and X11, add an API to retrieve the EGLDisplay
if one is being used in place of WGL.
Matthias Clasen [Tue, 11 May 2021 12:42:50 +0000 (12:42 +0000)]
Merge branch 'ebassi/egl-display-get' into 'master'
Add backend-specific getter for the EGLDisplay
See merge request GNOME/gtk!3542
Emmanuele Bassi [Tue, 11 May 2021 11:26:55 +0000 (12:26 +0100)]
wayland: Add EGLDisplay getter
Getting an EGLDisplay object is messy; might as well expose the function
we use internally to save some time, just like we did for the X11
backend.
Emmanuele Bassi [Tue, 11 May 2021 11:25:38 +0000 (12:25 +0100)]
x11: Add EGLDisplay getter
Getting an EGLDisplay object is messy; might as well expose the function
we use internally to save some time.
Emmanuele Bassi [Tue, 11 May 2021 11:24:34 +0000 (12:24 +0100)]
build: Do not use C arguments with C++
Otherwise the C++ compiler will start to complain.
The C++ keyword test does not need additional warnings.
Matthias Clasen [Tue, 11 May 2021 10:51:31 +0000 (10:51 +0000)]
Merge branch 'misc-inspector-things' into 'master'
inspector: Show text direction
See merge request GNOME/gtk!3541
Matthias Clasen [Tue, 11 May 2021 01:25:08 +0000 (21:25 -0400)]
inspector: Avoid a crash with GL variants
When configuring the inspector display, preserve
debug flags that affect which GL variant we pick.
Otherwise, we may end up with a GLX context on the
default display, and an EGL context on the inspector
one. This hopelessly confuses libepoxy, and things
don't go well when that happens.
Matthias Clasen [Tue, 11 May 2021 01:24:50 +0000 (21:24 -0400)]
inspector: Show EGL info for X11 as well
Matthias Clasen [Tue, 11 May 2021 00:55:43 +0000 (20:55 -0400)]
inspector: Show text direction
This is not a property, so show it on the misc tab.
Emmanuele Bassi [Mon, 10 May 2021 22:51:11 +0000 (22:51 +0000)]
Merge branch 'ebassi/egl-x11' into 'master'
Prefer EGL to GLX for the GL support on X11
See merge request GNOME/gtk!3540
Emmanuele Bassi [Mon, 10 May 2021 20:19:14 +0000 (21:19 +0100)]
x11: Don't update GLX visuals with EGL
We're going to get into a messy situation, with both GLX and EGL
initialized.
If we're already using EGL, skip the whole cache.
Matthias Clasen [Mon, 10 May 2021 20:11:38 +0000 (20:11 +0000)]
Merge branch 'broadway-display-scale' into 'master'
broadway: Add a setter for display scale
Closes #3934
See merge request GNOME/gtk!3538
Emmanuele Bassi [Mon, 10 May 2021 19:37:13 +0000 (20:37 +0100)]
x11: Always fall back to GLX on NVIDIA
At least until we can guarantee that EGL-X11 works fine there.
Emmanuele Bassi [Mon, 10 May 2021 19:33:02 +0000 (20:33 +0100)]
x11: Move the damage fences into the GLX code
It's GLX-specific anyway, there's no need to complicate things by having
half the code in the generic path, and half in the GLX one.
Emmanuele Bassi [Mon, 10 May 2021 17:36:32 +0000 (18:36 +0100)]
x11: Add debug toggle for preferring GLX
Mostly as a way to compare the EGL and GLX implementations.
Emmanuele Bassi [Mon, 10 May 2021 17:22:34 +0000 (18:22 +0100)]
x11: Add profiler marks for SwapBuffers
Emmanuele Bassi [Mon, 10 May 2021 17:11:05 +0000 (18:11 +0100)]
x11: Use EGL for GL support
This makes the X11 backend similar to the Wayland one, when it comes to
OpenGL.
Fall back to GLX only if EGL support is not available.
Emmanuele Bassi [Mon, 10 May 2021 14:07:08 +0000 (15:07 +0100)]
x11: Decouple GLX from GdkX11GLContext
If we want to add an EGL implementation for the X11 backend, we are
going to need to move the GLX bits into their own class. The first step
is to declare GdkX11GLContext as an abstract type, and then subclass it
into a GdkX11GLContextGLX type, which includes the whole GLX
implementation.
Matthias Clasen [Mon, 10 May 2021 14:55:41 +0000 (10:55 -0400)]
inspector: Support scale changes on Broadway
Matthias Clasen [Mon, 10 May 2021 13:26:54 +0000 (13:26 +0000)]
Merge branch 'ci-more-clang' into 'master'
ci: Add clang-extra-tools to the image
See merge request GNOME/gtk!3539
Matthias Clasen [Mon, 10 May 2021 12:51:37 +0000 (08:51 -0400)]
ci: Add clang-extra-tools to the image
Hurray for bite-size packages! Splitting
this off broke our style check in ci.
Matthias Clasen [Sun, 9 May 2021 23:42:42 +0000 (19:42 -0400)]
broadway: Add a setter for display scale
This is useful when using Broadway as a headless
display server.
Fixes: #3934
Matthias Clasen [Sun, 9 May 2021 23:32:36 +0000 (19:32 -0400)]
Cosmetics
Matthias Clasen [Sun, 9 May 2021 23:06:49 +0000 (23:06 +0000)]
Merge branch 'file-replace-trap' into 'master'
print-editor: Fix saving
See merge request GNOME/gtk!3536
Matthias Clasen [Sun, 9 May 2021 23:06:25 +0000 (23:06 +0000)]
Merge branch 'wip/exalm/image-button' into 'master'
Ensure consistent header bar buttons in the demo and tests
See merge request GNOME/gtk!3537
Alexander Mikhaylenko [Sun, 9 May 2021 15:53:40 +0000 (20:53 +0500)]
test: Ensure .image-button on header bar buttons
Alexander Mikhaylenko [Sun, 9 May 2021 15:53:05 +0000 (20:53 +0500)]
demo: Ensure .image-button on header bar buttons
Alexander Mikhaylenko [Sun, 9 May 2021 15:52:48 +0000 (20:52 +0500)]
test: Use more appropriate back/forward icons
Alexander Mikhaylenko [Sun, 9 May 2021 15:35:39 +0000 (20:35 +0500)]
demo: Use more appropriate back/forward icons
Matthias Clasen [Sun, 9 May 2021 15:17:48 +0000 (11:17 -0400)]
inspector: Fix saving css
g_file_replace_contents() does not accept -1
as length, unlike similar apis.
Matthias Clasen [Sun, 9 May 2021 15:16:52 +0000 (11:16 -0400)]
print-editor: Fix saving
g_file_replace_contents() does not accept -1 as
length, unlike similar apis.
Matthias Clasen [Sun, 9 May 2021 14:43:03 +0000 (14:43 +0000)]
Merge branch 'matthiasc/for-master' into 'master'
fontbutton: Quote font family names
See merge request GNOME/gtk!3534
Matthias Clasen [Sun, 9 May 2021 14:40:19 +0000 (14:40 +0000)]
Merge branch 'wip/exalm/actionbar' into 'master'
GtkActionBar spacing fixes
See merge request GNOME/gtk!3535
Alexander Mikhaylenko [Sun, 9 May 2021 12:01:36 +0000 (17:01 +0500)]
theme: Fix GtkActionBar spacing
Alexander Mikhaylenko [Sun, 9 May 2021 11:55:48 +0000 (16:55 +0500)]
actionbar: Fix the css node docs
Alexander Mikhaylenko [Sun, 9 May 2021 11:54:59 +0000 (16:54 +0500)]
action-bar: Add start and end style classes to GtkActionBar boxes
Make it possible to add spacing to them from the theme without affecting
the center child should it happen to be a box.
Matthias Clasen [Sun, 9 May 2021 00:53:44 +0000 (20:53 -0400)]
fontbutton: Quote font family names
Otherwise, spaces in family names will trip up
the css parser.
Matthias Clasen [Sat, 8 May 2021 02:07:18 +0000 (02:07 +0000)]
Merge branch 'emoji-full-locale' into 'master'
emoji: Try to load emoji data using both language and territory
See merge request GNOME/gtk!3531
Matthias Clasen [Fri, 7 May 2021 14:55:16 +0000 (14:55 +0000)]
Merge branch 'wip/carlosg/map-emulated-moveresize-window' into 'master'
gdk/x11: Ensure to map the non-ewmh moveresize emulation window before use
See merge request GNOME/gtk!3529
Marco Trevisan (Treviño) [Fri, 7 May 2021 14:03:37 +0000 (16:03 +0200)]
emoji: Try to load emoji data using both language and territory
When loading the emoji data we just try to get the data for a language
while there may be territory specializations and emojibase provides
them.
So, split the loading function and try to load the data for the fully
defined language string (i.e. `it-ch`) before loading the generic one
for the language (i.e. `it`) and eventually falling back to the generic
english.
Carlos Garnacho [Fri, 7 May 2021 13:51:52 +0000 (15:51 +0200)]
gdk/x11: Ensure to map the non-ewmh moveresize emulation window before use
Otherwise, we don't deem it as able to be grabbed, which we intend to do
immediately after.
Matthias Clasen [Fri, 7 May 2021 12:57:55 +0000 (12:57 +0000)]
Merge branch 'matthiasc/for-master' into 'master'
Add some calendar tests
See merge request GNOME/gtk!3528
Matthias Clasen [Fri, 7 May 2021 11:43:19 +0000 (07:43 -0400)]
Add some calendar tests
Check that the getters and setters work as documented.
This tests the fix in
1f8985e47623421.
Matthias Clasen [Fri, 7 May 2021 11:42:59 +0000 (11:42 +0000)]
Merge branch 'carlosgc/calendar-day' into 'master'
calendar: value of day property is shifted by 1
See merge request GNOME/gtk!3524
Matthias Clasen [Fri, 7 May 2021 11:08:57 +0000 (11:08 +0000)]
Merge branch 'fix-3918' into 'master'
demos: Mark non-static signal handler symbols for export
Closes #3918
See merge request GNOME/gtk!3523
Matthias Clasen [Fri, 7 May 2021 11:05:46 +0000 (11:05 +0000)]
Merge branch 'update-emoji-data' into 'master'
emoji: Update data to CLRD v39
See merge request GNOME/gtk!3520
Carlos Garcia Campos [Fri, 7 May 2021 10:13:49 +0000 (12:13 +0200)]
calendar: do not allow to set 0 as day
We no longer unselect the current day when 0 is set, so update the
documentation and the property definition.
Carlos Garcia Campos [Fri, 7 May 2021 09:10:36 +0000 (11:10 +0200)]
calendar: value of day property is shifted by 1
The day is a number between 1 and 31 and that's what we get from
GDateTime.
Chun-wei Fan [Thu, 6 May 2021 09:21:46 +0000 (17:21 +0800)]
demos: Mark non-static signal handler symbols for export
The symbols in the .ui files for the signal handlers and functions must be
exported so that the system can pick them up during execution.
Fixes #3918.
Matthias Clasen [Fri, 7 May 2021 00:34:33 +0000 (00:34 +0000)]
Merge branch 'hidden-mnemonics-fix' into 'master'
label: Make hidden mnemonics work again
See merge request GNOME/gtk!3518
Matthias Clasen [Thu, 6 May 2021 15:33:15 +0000 (15:33 +0000)]
Merge branch 'emoji-data-prefix-fix' into 'master'
emoji: Use a portable and configuration-dependent path to load the data
See merge request GNOME/gtk!3522
Matthias Clasen [Thu, 6 May 2021 15:26:49 +0000 (15:26 +0000)]
Merge branch 'macos' into 'master'
Fix building both X11 and Quartz backends on macOS
See merge request GNOME/gtk!3508
Marco Trevisan (Treviño) [Thu, 6 May 2021 13:34:30 +0000 (15:34 +0200)]
emoji: remove duplicated include
Marco Trevisan (Treviño) [Thu, 6 May 2021 13:32:44 +0000 (15:32 +0200)]
emoji: Use a portable and configuration-dependent path to load the data
Load the emojis data in all the platforms, respecting the configured
GTK_DATA_PREFIX
Dan Cîrnaț [Tue, 4 May 2021 11:52:21 +0000 (13:52 +0200)]
Fix compilation of c++ test: cpp_args
The correct meson argument for c++ is cpp_args.
Remove unnecessary(?) "-Idummy-headers" - breaks build
Dan Cîrnaț [Tue, 4 May 2021 11:51:35 +0000 (13:51 +0200)]
Only compile gtkmountoperation-stub if the X11 backend is not enabled